/*
 * Copyright (c) 2015. For Intelligent Group.
 */

package com.intelligent.ispc.core.dto;


import com.intelligent.ispc.common.dto.AbstractValueObject;

/**
 * Created by yangli on 2015-07-15.
 */
public class ProjectDto extends AbstractValueObject {

    private Long id;
    private String code;
    private String name;
    private String description;
    private String createBy;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy;
    }

    @Override
    public boolean equals(Object obj) {
        boolean flag = false;
        if (obj instanceof ProjectDto) {
            ProjectDto projectDto = (ProjectDto) obj;
            if (projectDto.getId() == this.getId() || projectDto.getName() == this.getName()) {
                flag = true;
            }
        }
        return flag;
    }
}
